﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using SalaDeEnsayo.ApplicationService;

namespace SalaDeEnsayo.WebApplication
{
    public partial class Login : System.Web.UI.Page
    {
        MembershipService membershipService;

        public Login()
        {
            membershipService = new MembershipService();
        }

        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void Login1_Authenticate(object sender, AuthenticateEventArgs e)
        {
            bool autenthicate = false;
            autenthicate = membershipService.ContraseniaValida(Login1.UserName, Login1.Password);
            if (autenthicate)
                e.Authenticated = true;
        }
    }
}
